Skip to content

refactor(dossiq): lock and unlock documents through a LockRequest - #5358

Closed
rubenvdlinde wants to merge 3 commits into
developmentfrom
fix/or-surface-lock-request
Closed

rubenvdlinde wants to merge 3 commits into
developmentfrom
fix/or-surface-lock-request

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

Merge after openregister #9095 lands.

LockRequest, UnlockRequest and LockRunStep are new in OCA\OpenRegister\Service\Object in #9095, so this has to land with #9095 or after it.

Fixed (file -> new call)

  • lib/Controller/DrcController.php:876: lockObject(identifier: $uuid) -> lockObject(request: new LockRequest(identifier: $uuid))
  • lib/Controller/DrcController.php:1017: unlockObject(identifier: $uuid) -> unlockObject(request: new UnlockRequest(identifier: $uuid))

Tests

  • tests/Stubs/Contract/ObjectServiceInterface.php: both methods on #9095's signature. The three value-object stubs are copied from #9095's head.
  • DrcDownloadLockContractTest and DrcControllerContractTest: the doubled interfaces and the lock callback and unlock with() take the request objects.

What ran

  • php -l and phpcs (no errors) on the controller.
  • PHPUnit --no-coverage on every test that uses the object-service interface stub or the DRC controller: green.
  • Control: both contract tests fail against the old calls.

AI disclosure: prepared with Claude Code (claude-opus-5-5).

openregister #9095 changes lockObject() and unlockObject() to take a
LockRequest and an UnlockRequest. The DRC lock and unlock endpoints build
them from the document uuid.

Assisted-by: ClaudeCode:claude-opus-5-5
@github-actions

Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/dossiq @ 6bb45c7

Check PHP Vue Security License Tests
lint ✅
phpcs ✅
phpmd ❌
psalm ✅
phpstan ✅
phpmetrics ✅
eslint ❌
stylelint ✅
build ✅
check-manifest ✅
check-vue3-compile ✅
test-l10n ✅
format ❌
check-schema-l10n ❌
check-l10n-js ✅
check-debt-ratchet ❌
check-types-e2e ✅
composer ❌ ✅ 109/109
npm ✅ ✅ 657/657
app:check-code ⏭️
info.xml ✅
REUSE ❌
lockfile sync ✅
PHPUnit ❌ 3909/3944 · 3 skipped
Newman ⏭️
Playwright ⏭️ deferred: E2E runs locally and on the promotion path only. This pull request targets development, so the suite is asked once per promotion into beta and main rather than once per push per open pull request. Run it locally with npx playwright test, or from the Actions tab on a branch with no open pull request into development.
Hydra gates ❌

Quality workflow — 2026-11-10 22:57 UTC

Download the full PDF report from the workflow artifacts.

… Kernel\Contracts\Value [skip ci]

OpenRegister main defines them there; the Service\Object names existed only
in the test stubs, so lock and unlock failed at runtime. The stubs move to
the same namespace.

Assisted-by: ClaudeCode:claude-opus-5-5
Assisted-by: ClaudeCode:claude-opus-5-5

# Conflicts:
#	lib/Controller/DrcController.php
@rubenvdlinde

Copy link
Copy Markdown
Contributor Author

Superseded by #6581 (merged into development), which moves every find/saveObject/deleteObject/patchObject/lock call and flow node in this app to openregister main's option objects in one pass, test doubles included.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant